//
//  MessageViewController.m
//  SinaWebo
//
//  Created by 亦心 on 15/3/7.
//  Copyright (c) 2015年 亦心. All rights reserved.
//

#import "MessageViewController.h"
#import <UIImageView+WebCache.h>
#import "UIBarButtonItem+Extension.h"
#import "LocationTool.h"

@interface MessageViewController ()
@property (weak, nonatomic) UIImageView *imageView;
@end

@implementation MessageViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
    self.navigationItem.rightBarButtonItem=[[UIBarButtonItem alloc]initWithTitle:@"写私信" style:UIBarButtonItemStyleDone target:self action:nil];
    
    UIImageView *imageView = [[UIImageView alloc] init];
    imageView.frame = CGRectMake(20, 22, 300, 300);
    [self.view addSubview:imageView];
    
    [imageView sd_setImageWithURL:[NSURL URLWithString:@"http://t.cn/RqmHLOo"] completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, NSURL *imageURL) {
        MyLog(@"");
    }];
    
    [[LocationTool sharedLocation] location:^(CLLocationCoordinate2D coordinate, CLPlacemark *placemark) {
        MyLog(@"%@", placemark.name);
    }];
}


@end
